<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>体验Vue.js</title>
</head>
<body>
    
    <p>体验双向绑定</p>
    
    <div id="app">
        <input type="text" v-model="nickname">
        <div>{{nickname}}</div>
    </div>
    
    <!-- 导入 vue.js 文件 -->
    <script src="https://unpkg.com/vue@next"></script>
    <!-- 用另外一个 script 元素书写自己的代码 -->
    <script type="text/javascript">

        const options = {
            data(){
                return { 
                    nickname: ''
                }
            }
        }

        const app = Vue.createApp( options );
        console.log( app );
        app.mount( '#app' );
    </script>
</body>
</html>